//=================================获取系统时间==============================================
var now=new Date()
var years,months,days,hours,minutes,seconds
years=now.getFullYear()
months=now.getMonth()+1
days=now.getDate()
hours=now.getHours()
minutes=now.getMinutes()
seconds=now.getSeconds()
$('#set_date').html('日期：'+years+'-'+months+'-'+days+' &gt;').append('<input hidden class="_date" value="'+years+'-'+months+'-'+days+' '+hours+':'+minutes+':'+seconds+'">')

//==============================首页选中时间===============================
//var marks=['2018-06-27','2018-06-28','2018-06-29','2018-06-30']
var set_date_info={
        theme:{bgcolor:"#00B8EE",pnColor:"#00CCFF"},
        format: "日期: YYYY-MM-DD >",
        isClear:false,	// 不显示清空
        trigger:"click",
//         marks:marks,
        donefun:function(obj){
        	var sp=obj.val.split(' ')[1].toString()+' '+hours+':'+minutes+':'+seconds
        	console.log('已选时间'+sp)
          	defaultRequest.Ajax(sp)
        }
    }

	jeDate("#set_date",set_date_info);
//=============================节目表 选择日期=============================
	var start = {}, end = {};
	jeDate('#inpstart',{   //  开始时间
		theme:{bgcolor:"#00B8EE",pnColor:"#00CCFF"},
        format: "YYYY-MM-DD hh:mm:ss",
        isClear:true,
        isTime:true,
        donefun: function(obj){
            end.minDate = obj.val.split(' ')[0]; //开始日选好后，重置结束日的最小日期
            jeDate("#inpend",LinkageEndDate(false));
        }
	})
	jeDate('#inpend',LinkageEndDate)   //  结束时间
	function LinkageEndDate(istg) {
        return {
        	theme:{bgcolor:"#00B8EE",pnColor:"#00CCFF"},
        	format: "YYYY-MM-DD hh:mm:ss",
            trigger : istg || "click",
            maxDate: '2020-05-20 23:59:59', //设定最大日期为当前日期
            donefun: function(obj){
                start.maxDate = obj.val; //将结束日的初始值设定为开始日的最大日期
            }
        };    
    }

//===================================时间点================================================
    jeDate('#choosePlayDate',{
        theme:{bgcolor:"#00B8EE",pnColor:"#00CCFF"},
        format: "hh:mm:ss",
    })
        var start = {}, end = {};
    jeDate('#inpstarts',{   //  开始时间
        theme:{bgcolor:"#00B8EE",pnColor:"#00CCFF"},
        format: "YYYY-MM-DD hh:mm:ss",
        isClear:true,
        isTime:true,
        donefun: function(obj){
            end.minDate = obj.val.split(' ')[0]; //开始日选好后，重置结束日的最小日期
            jeDate("#inpend",LinkageEndDate(false));
        }
    })
    jeDate('#inpends',LinkageEndDate)   //  结束时间
    function LinkageEndDate(istg) {
        return {
            theme:{bgcolor:"#00B8EE",pnColor:"#00CCFF"},
            format: "YYYY-MM-DD hh:mm:ss",
            trigger : istg || "click",
            maxDate: '2020-05-20 23:59:59', //设定最大日期为当前日期
            donefun: function(obj){
                start.maxDate = obj.val; //将结束日的初始值设定为开始日的最大日期
            }
        };    
    }

